package com.campus.common.message;

import java.io.Serializable;
import java.util.List;

import com.campus.common.vo.Classroom;
import com.campus.common.vo.Course;
import com.campus.common.vo.Student;

/**
 * 教师端课程/班级/学生操作响应
 */
public class TeacherCourseResponse implements Serializable {
    private boolean success;       // 操作是否成功
    private String message;        // 提示信息

    // ===== 课程相关 =====
    private Course course;         // 单个课程
    private List<Course> courses;  // 多个课程

    // ===== 班级相关 =====
    private Classroom classroom;        // 单个班级
    private List<Classroom> classrooms; // 多个班级

    // ===== 学生相关 =====
    private Student student;       // 单个学生
    private List<Student> students;// 学生列表（例如某个班级的学生名单）

    // ===== 构造器 =====
    public TeacherCourseResponse() {}

    // 操作结果 + 提示
    public TeacherCourseResponse(boolean success, String message) {
        this.success = success;
        this.message = message;
    }

    // 单个课程
    public TeacherCourseResponse(boolean success, String message, Course course) {
        this.success = success;
        this.message = message;
        this.course = course;
    }

    // 多个课程
    public TeacherCourseResponse(boolean success, String message, List<Course> courses, boolean isCourseList) {
        this.success = success;
        this.message = message;
        this.courses = courses;
    }

    // 单个班级
    public TeacherCourseResponse(boolean success, String message, Classroom classroom) {
        this.success = success;
        this.message = message;
        this.classroom = classroom;
    }

    // 多个班级
    public TeacherCourseResponse(boolean success, String message, List<Classroom> classrooms, int dummy) {
        this.success = success;
        this.message = message;
        this.classrooms = classrooms;
    }

    // 学生列表
    public TeacherCourseResponse(boolean success, String message, List<Student> students) {
        this.success = success;
        this.message = message;
        this.students = students;
    }

    // ===== Getter / Setter =====
    public boolean isSuccess() { return success; }
    public void setSuccess(boolean success) { this.success = success; }

    public String getMessage() { return message; }
    public void setMessage(String message) { this.message = message; }

    public Course getCourse() { return course; }
    public void setCourse(Course course) { this.course = course; }

    public List<Course> getCourses() { return courses; }
    public void setCourses(List<Course> courses) { this.courses = courses; }

    public Classroom getClassroom() { return classroom; }
    public void setClassroom(Classroom classroom) { this.classroom = classroom; }

    public List<Classroom> getClassrooms() { return classrooms; }
    public void setClassrooms(List<Classroom> classrooms) { this.classrooms = classrooms; }

    public Student getStudent() { return student; }
    public void setStudent(Student student) { this.student = student; }

    public List<Student> getStudents() { return students; }
    public void setStudents(List<Student> students) { this.students = students; }
}

